<?php

namespace plugin\ycMassage\app\validate;

use think\Validate;


class MassageUser extends Validate
{
    protected $rule =   [
        'mobile'  => 'require|mobile',
        'nickname'   => 'require',
        'headimg'   => 'require',
        'password' => 'require',
    ];

    protected $message  =   [
        'mobile.require' => '手机号必须',
        'mobile.mobile'     => '手机号格式错误',
        'nickname.require'   => '昵称必须',
        'headimg.require'   => '头像必须',
        'password.require'   => '密码必须',
    ];
    protected $scene = [
        'create'  =>  ['mobile', 'nickname', 'headimg', 'password'],
        'update'  =>  ['mobile', 'nickname', 'headimg'],
    ];
}
